package com.wumai.keystrokes.models.display;

import net.minecraft.util.ResourceLocation;

/**
 * @author trick12138
 * @date 2025-10-16
 * @description 纹理资源模型，支持指定资源位置及从中截取的区域
 */
public class TextureResource {
    private ResourceLocation resourceLocation;
    private int u; // 截取区域的左上角U坐标
    private int v; // 截取区域的左上角V坐标
    private int width;  // 截取区域的宽度
    private int height; // 截取区域的高度

    public int getTextureWidth() {
        return textureWidth;
    }

    public void setTextureWidth(int textureWidth) {
        this.textureWidth = textureWidth;
    }

    public int getTextureHeight() {
        return textureHeight;
    }

    public void setTextureHeight(int textureHeight) {
        this.textureHeight = textureHeight;
    }

    private int textureWidth;
    private int textureHeight;
    
    public TextureResource() {}
    
    public TextureResource(ResourceLocation resourceLocation, int u, int v, int width, int height, int textureWidth, int textureHeight) {
        this.resourceLocation = resourceLocation;
        this.u = u;
        this.v = v;
        this.width = width;
        this.height = height;
        this.textureWidth = textureWidth;
        this.textureHeight = textureHeight;
    }
    
    public ResourceLocation getResourceLocation() {
        return resourceLocation;
    }
    
    public void setResourceLocation(ResourceLocation resourceLocation) {
        this.resourceLocation = resourceLocation;
    }
    
    public int getU() {
        return u;
    }
    
    public void setU(int u) {
        this.u = u;
    }
    
    public int getV() {
        return v;
    }
    
    public void setV(int v) {
        this.v = v;
    }
    
    public int getWidth() {
        return width;
    }
    
    public void setWidth(int width) {
        this.width = width;
    }
    
    public int getHeight() {
        return height;
    }
    
    public void setHeight(int height) {
        this.height = height;
    }
}